#if !defined(AFX_IPACCESSSTATESSHOWDLG_H__92510ABD_D510_4D40_B098_5983A6B38FF7__INCLUDED_)
#define AFX_IPACCESSSTATESSHOWDLG_H__92510ABD_D510_4D40_B098_5983A6B38FF7__INCLUDED_

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
// IpAccessStatesShowDlg.h : header file
//

#include "Resource.h"
#include "ListCtrlIpAccessStatesShow.h"

/////////////////////////////////////////////////////////////////////////////
// CIpAccessStatesShowDlg dialog

class CIpAccessStatesShowDlg : public CDialog
{
// Construction
public:
	CIpAccessStatesShowDlg(const CString &strName, CWnd* pParent = NULL);   // standard constructor

// Dialog Data
public:
	//{{AFX_DATA(CIpAccessStatesShowDlg)
	enum { IDD = IDD_IP_ACCESS_STATES_SHOW };
	CListCtrlIpAccessStatesShow	m_clstIpAccessStates;
	//}}AFX_DATA
	CString m_strName;
protected:
	enum EIpAccessState
	{
		NO_ADMITTANCE = 0,
		ADMITTANCE = 1
	};
	CMap<CString,LPCTSTR,EIpAccessState,EIpAccessState> m_mapIpsAccessState;

// Overrides
	// ClassWizard generated virtual function overrides
	//{{AFX_VIRTUAL(CIpAccessStatesShowDlg)
	protected:
	virtual void DoDataExchange(CDataExchange* pDX);    // DDX/DDV support
	virtual void PostNcDestroy();
	//}}AFX_VIRTUAL

// Implementation
protected:
	virtual CStringItemsArray GetRoles(const CString &strRoleName);
	void SetIpAccessStatesData(CStringItemsArray &arrRoles);
	CStringItemsArray GetAdmittances(const CArray<CString,LPCTSTR> &arrRoleNames);

	CRect GetPosition();

	// Generated message map functions
	//{{AFX_MSG(CIpAccessStatesShowDlg)
	virtual BOOL OnInitDialog();
	afx_msg void OnKillfocusLstIpAccessStates(NMHDR* pNMHDR, LRESULT* pResult);
	afx_msg void OnSize(UINT nType, int cx, int cy);
	afx_msg void OnClose();
	//}}AFX_MSG
	DECLARE_MESSAGE_MAP()
};

//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.

#endif // !defined(AFX_IPACCESSSTATESSHOWDLG_H__92510ABD_D510_4D40_B098_5983A6B38FF7__INCLUDED_)
